﻿@using CashFlow.Web.Areas.ShopManage.Models.Order.Result;
@{
    ViewBag.Title = "Index";
    var ls = ViewBag.UserList as IList<OrderUserInfoModel>;
}

<style type="text/css">
    td {
        padding: 5px;
    }

    .buyer {
        color: green;
        font-size: 16px;
    }

    .seller {
        color: red;
        font-size: 16px;
    }

    .userList {
        width: 100%;
        height: 140px;
        overflow: scroll;
        border: 1px solid #eeeeee;
    }

        .userList li {
            list-style-type: none;
            display: block;
            height: 25px;
            line-height: 25px;
            float: left;
            font-size: 16px;
            margin-right: 10px;
            margin-bottom: 10px;
        }

    .ViewOrderPremiumTableDlg-list li {
        display: block;
        list-style-type: none;
        float: left;
        margin-right: 10px;
        margin-bottom: 10px;
    }
</style>

<form class="layui-form" style="padding-top: 10px;">
    <table width="70%" align="center" id="Table1">
        <tr>
            <td align="right" width="60">买家:</td>
            <td><label id="lbBuyer" class="buyer">未选择！</label></td>
        </tr>
        <tr>
            <td align="right">卖家:</td>
            <td><label id="lbSeller" class="seller">未选择！</label></td>
        </tr>
        <tr>
            <td align="right">订单金额:</td>
            <td>
                <input type="number" class="layui-input" maxlength="12" id="txtAmount"
                       step="0.01" lay-affix="number"
                       min="1000" max="15000" value="" />
            </td>
        </tr>
        <tr>
            <td colspan="2">
                <div style="float: left;">
                    <button type="button" id="btnSetOrderPremiumTable"
                            class="layui-btn layui-btn-sm">
                        <i class="layui-icon layui-icon-set"></i>设置订单溢价表
                    </button>
                </div>
                <div style="float: left; margin-left: 10px;">
                    <button type="button" id="btnQueryOrderPremiumTable"
                            class="layui-btn layui-btn-sm">
                        <i class="layui-icon layui-icon-search"></i>查询订单溢价表
                    </button>
                </div>
            </td>
        </tr>
        <tr>
            <td>&nbsp;&nbsp;</td>
            <td>
                <button type="button" id="btnCreateOrderOK"
                        class="layui-btn layui-btn-normal">
                    <i class="layui-icon layui-icon-add-1"></i>创 建
                </button>
            </td>
        </tr>
    </table>
    <table align="center" width="80%" style="margin-top: 10px;">
        <tr>
            <td align="right" width="60"><label style="color: red;">卖家:</label></td>
            <td style="padding-right: 0px;">
                <input type="text" class="layui-input" id="txtSearchSeller"
                       style="width: 140px;" maxlength="10" />
            </td>
            <td align="left" style="padding-left: 0px;">
                <button type="button" id="btnSearchSeller"
                        class="layui-btn layui-btn-normal">
                    <i class="layui-icon layui-icon-search"></i>搜 索
                </button>
            </td>
        </tr>
        <tr>
            <td colspan="3">
                <div class="userList" id="SellerList">
                    <ul>
                        @foreach (var item in ls)
                        {
                            <li tagUserId="@item.Id" tagPhone="@item.Phone">@item.Name</li>
                        }
                    </ul>
                </div>
            </td>
        </tr>
        <tr>
            <td align="right" width="60"><label style="color: green;">买家:</label></td>
            <td style="padding-right: 0px;">
                <input type="text" class="layui-input" id="txtSearchBuyer"
                       style="width: 140px;" maxlength="10" />
            </td>
            <td align="left" style="padding-left: 0px;">
                <button type="button" id="btnSearchBuyer"
                        class="layui-btn layui-btn-normal">
                    <i class="layui-icon layui-icon-search"></i>搜 索
                </button>
            </td>
        </tr>
        <tr>
            <td colspan="3">
                <div class="userList" id="BuyerList">
                    <ul>
                        @foreach (var item in ls)
                        {
                            <li tagUserId="@item.Id" tagPhone="@item.Phone">@item.Name</li>
                        }
                    </ul>
                </div>
            </td>
        </tr>
    </table>
</form>

<script type="text/html" id="SetOrderPremiumTableDlg">
    <form class="layui-form" style="padding: 10px;">
        <table>
            <tr>
                <td>选择日期:</td>
                <td>
                    <input type="text" class="layui-input" readonly="readonly"
                           style="width: 140px;" id="Txt-SetOrderPremiumTableDlg-Date" />
                </td>
            </tr>
            <tr>
                <td>&nbsp;&nbsp;</td>
                <td>
                    <button type="button" id="btn-SetOrderPremiumTableDlg-OK"
                            class="layui-btn layui-btn-normal">
                        <i class="layui-icon layui-icon-ok"></i>查 询
                    </button>
                </td>
            </tr>
        </table>
    </form>
</script>

<script type="text/html" id="ViewOrderPremiumTableDlg">
    <form class="layui-form" style="padding: 10px;">
        <div id="ViewOrderPremiumTableDlg-List" class="ViewOrderPremiumTableDlg-list">
            <ul>
            </ul>
        </div>
    </form>
</script>

<script type="text/javascript" src="~/Static/Js/shopmanage/createorder.js?rand=01234567"></script>